package com.kin207.netty.server;

import com.google.common.eventbus.EventBus;
import com.kin207.netty.handle.IMessageHandleAdapter;
import com.kin207.netty.msg.IMessageParse;
import com.kin207.netty.session.SessionManager;

import io.netty.channel.ChannelInitializer;

public interface IServer {
	public void run() throws InterruptedException;
	
	public String getName();
	
	public void setName(String name);
	
	public ServerManager getServerManager();
	
	public void setServerManager(ServerManager server);

	public int getPort();

	public void setPort(int port);

	public ChannelInitializer getChannelInitializer();
	
	public void setChannelInitializer(ChannelInitializer channelInitializer);

	public SessionManager getSessionManager();

	public void setSessionManager(SessionManager sessionManager);
	
	public IMessageHandleAdapter getMessageHandleAdapter();
	
	public void setMessageHandleAdapter(IMessageHandleAdapter messageHandleAdapte);
	
	public IMessageParse getMessageParse();
	
	public void setMessageParse(IMessageParse messageParse);
	
	public void setEventBus(EventBus eventBus);
	
	public EventBus getEventBus();
	
	public String getServerType();
	
	public void close();
	
}
